package com.example.sell.enums;

import lombok.Getter;

/**
 * @author: vince_zww
 * @date: 2020/8/17 16:31
 * @desceription: 统一异常处理
 */
@Getter
public enum ResultEnum {

    PARAM_ERROR(101,"参数不正确"),

    CONVERT_ERROR(102,"jsong转换异常"),

    PRODUCT_NOT_EXIST(1001,"商品不存在"),
    PRODUCT_STOCK_ERROR(1002,"商品库存不正确"),


    ORDER_NOT_EXIST(1101,"订单不存在"),
    ORDERDETAIL_NOT_EXIST(1102,"订单详情不存在"),
    ORDER_STATUS_ERROR(1103,"订单状态异常"),
    ORDER_UPDATE_FAIL(1104,"订单更新失败"),
    ORDER_DETAIL_EMPTY(1105,"订单详情为空"),
    ORDER_PAY_STATUS_ERROR(1106,"订单支付状态异常"),
    CART_EMPTY(1107,"购物车为空"),
    ORDER_OWNER_ERROR(1108,"该订单不属于当前用户"),


    WECHAT_MP_ERROR(1201,"微信公众账号方面错误"),
    WECHAT_APY_NOTIFY_MONEY_VERIFY_ERROR(1202,"微信支付异步通知金额校验不通过"),




    ;

    private Integer code;

    private String message;

    ResultEnum(Integer code, String message) {
        this.code = code;
        this.message = message;
    }


}
